package RequestTest;
use strict;
use warnings;

use base qw(Test::Class);
use Test::More;
use Data::Dumper;

use lib '/home/'.$ENV{USER}.'/djpp/core/t';
use lib '/home/'.$ENV{USER}.'/djpp/core/model';
use lib '/home/'.$ENV{USER}.'/djpp/core/t/model';

use MockObjects;
use Request;

sub testSetup : Test(setup)
{
	my $self = shift;
	
	$self->{req} = new Request( realrequest => MockObjects::getApacheMock() );
}

sub testUri : Test
{
	my $self = shift;
	
	ok($self->{req}->uri, 'Uri defined');	
}

sub testCookie : Test
{
	my $self = shift;
	
	my $cookie = $self->{req}->cookie;
	ok($cookie);
}

sub testIp : Test
{
	my $self = shift;
	
	my $ip = $self->{req}->ip;
	
	ok($ip);
}
1;
